public class Person2 {
    private String name;

    public Person2(String name) {
        this.name = name;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }
    public void run(){
        System.out.println(getName()+"正在跑");
    }
    public void eat(){
        System.out.println(getName()+"正在吃");
    }
}
